package com.java2_13;

public class roleFighting {
    public static void main(String[] args) {
        Role r1 = new Role("zhangsan",100,'男');
        Role r2 = new Role("lisi",100,'男');

        while(true){
            r1.attack(r2);
            if (r2.getBlood() == 0) {
                System.out.println("zhangsan  K.O  lisi");
                break;
            }
            r2.attack(r1);
            if(r1.getBlood() == 0){
                System.out.println("lisi  K.O  zhangsan");
                break;
            }
        }




    }





}
